package cn.hl.hm.service.impl;

import cn.hl.hm.dao.VehicleMapper;
import cn.hl.hm.entity.Vehicle;
import cn.hl.hm.service.VehicleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @description:
 * @Author: xianghan
 * @Date: 2017/10/25 19:22
 **/
@Service
public class VehicleServiceImpl implements VehicleService {
    @Autowired
    private VehicleMapper vehicleDao;
    @Override
    public int deleteByPrimaryKey(Integer id) {
        return vehicleDao.deleteByPrimaryKey(id);
    }

    @Override
    public int insert(Vehicle record) {
        return vehicleDao.insert(record);
    }

    @Override
    public int insertSelective(Vehicle record) {
        return vehicleDao.insertSelective(record);
    }

    @Override
    public Vehicle selectByPrimaryKey(Integer id) {
        return vehicleDao.selectByPrimaryKey(id);
    }

    @Override
    public Vehicle selectByPlateNumber(String plateNumber) {
        return vehicleDao.selectByPlateNumber(plateNumber);
    }

    @Override
    public int updateByPrimaryKeySelective(Vehicle record) {
        return vehicleDao.updateByPrimaryKeySelective(record);
    }

    @Override
    public int updateByPrimaryKey(Vehicle record) {
        return vehicleDao.updateByPrimaryKey(record);
    }
}
